package com.rongzhe.house.common.rest;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 *  自定义分页
 */
@Data
@NoArgsConstructor
@AllArgsConstructor
public class CustomPage<T> {

    /**
     * 总数
     */
    private Long total;

    /**
     * 记录
     */
    private List<T> rows;


    public static CustomPage build(Long total, List rows) {
        return new CustomPage(total, rows);
    }

}
